package com.ysd.lis.controller.lab;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.entity.lab.LabInspectCompanySalesman;
import com.ysd.lis.request.lab.CompanyPageParam;
import com.ysd.lis.service.lab.LabInspectCompanySalesmanService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>
 * 送检单位对照销售人员 前端控制器
 * </p>
 *
 * @author WH
 * @since 2024-10-28
 */
@RestController
@RequestMapping("/lab/inspectCompanySalesman")
public class LabInspectCompanySalesmanController extends BaseController {
    @Autowired
    private LabInspectCompanySalesmanService inspectCompanySalesmanService;

    @ApiOperation("查询")
    @GetMapping("/findInspectCompanySalesmanList")
    public Result findInspectCompanySalesmanList(CompanyPageParam param) {
        return inspectCompanySalesmanService.findInspectCompanySalesmanList(param);
    }

    @ApiOperation("新增")
    @PostMapping("/addCompanySalesman")
    public Result addCompanySalesman(@RequestBody LabInspectCompanySalesman salesman) {
        return inspectCompanySalesmanService.addCompanySalesman(salesman);
    }

    @ApiOperation("批量删除")
    @PostMapping("/batchDeleteCompanySalesmanList")
    public Result batchDeleteCompanySalesmanList(@RequestBody List<LabInspectCompanySalesman> list) {
        return inspectCompanySalesmanService.batchDeleteCompanySalesmanList(list);
    }
}
